package com.xgc.book.bookserver.controller;

import org.apache.shiro.SecurityUtils;

/**
 * @Author PangJunjie
 * @Date 2023/11/29/029
 */
public abstract class BaseLoginController {
    public Integer getLoginId() {
        Object obj = SecurityUtils.getSubject().getPrincipal();
        if (obj != null) {
            return Integer.parseInt(obj.toString());
        }
        return null;
    }
}
